import { ajax } from '@/utils'

const baseUrl = '/monitor/loginLog'

export default {
  getLoginLogPage(...args: IGetLoginLogPageReq): Promise<IGetLoginLogPageRes> {
    return ajax.post(`${baseUrl}/page`, args[0])
  },
  exportLoginLogPage(...args: IGetLoginLogPageReq): IExportRes {
    return ajax.post(`${baseUrl}/export`, args[0])
  },
  deleteLoginLog(...args: IDeleteReq): IVoidRes {
    return ajax.delete(`${baseUrl}/delete`, { data: args[0] })
  },
  clearLoginLog(): IVoidRes {
    return ajax.delete(`${baseUrl}/clear`)
  }
}
